Auto merge of #3157 - japaric:target-rustflags, r=alexcrichton
authorbors <bors@rust-lang.org>
Wed, 5 Oct 2016 16:16:15 +0000 (09:16 -0700)
committerGitHub <noreply@github.com>
Wed, 5 Oct 2016 16:16:15 +0000 (09:16 -0700)
commit85df1880d84a83dfb28a2ec825f4c1abef3aac9e
tree36b6b8d8e9d497027311308d76b6350c1ecab6e6
parentfe0a4a7dd9fd2db95dc2935f48c74144089681fa
parentef727b7d895685b4debce922c7ee45796d76f0f2
Auto merge of #3157 - japaric:target-rustflags, r=alexcrichton

add support for per-target rustflags in .cargo/config

you can now specify rustflags on a per-target basis in .cargo/config:

``` toml
[target.x86_64-unknown-linux-gnu]
rustflags = ["x86", "specific", "flags"]

[target.arm-unknown-linux-gnueabi]
rustflags = ["arm", "specific", "flags"]
```

If both build.rustflags and target.*.rustflags are specified, the
target.* ones will be used.

As before RUSTFLAGS overrides either set.

closes #3153

r? @alexcrichton I've only added a smoke test and a precedence test. Let me know if I should add more tests!